package com.hc.domain;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author hecai
 * 商品类别表
 */
@ApiModel(value = "商品类别表")
@Getter
@Setter
@ToString
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "tb_goods_category")
public class ProductCategory implements Serializable {
    private static final long serialVersionUID = -4092878373417134370L;
    /**
     * 类别编号
     */
    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value = "类别编号")
    private Integer id;
    /**
     * 类别名称
     */
    @TableField(value = "`name`")
    @ApiModelProperty(value = "类别名称")
    private String name;
    /**
     * 备注信息
     */
    @TableField(value = "info")
    @ApiModelProperty(value = "备注信息")
    private String info;
    /**
     * 显示优化级
     */
    @TableField(value = "priority")
    @ApiModelProperty(value = "显示优化级")
    private Integer priority;
    /**
     * 父类别编号
     */
    @TableField(value = "pid")
    @ApiModelProperty(value = "父类别编号")
    private Integer pid;
    /**
     * 状态：1上架，2下架
     */
    @TableField(value = "`status`")
    @ApiModelProperty(value = "状态：1上架，2下架")
    private Integer status;
    /**
     * 创建时间
     */
    @TableField(value = "create_time",fill = FieldFill.INSERT)
    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createTime;
    /**
     * 更新时间
     */
    @TableField(value = "update_time",fill = FieldFill.UPDATE)
    @ApiModelProperty(value = "更新时间")
    private LocalDateTime updateTime;
}